package example.dao;

import example.pojo.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
public interface UserMapper {

    User selectByName(@Param("user") User user);

    User login(@Param("user") User pojo);

    User getUserById(@Param("id") long id);

    List<User> getUserlistByName(@Param("user") User pojo);

    List<User> getUserlistAll();

    void insert(@Param("user") User user);

    void update(@Param("user") User user);

    User getPwdByPhoneOrMail(@Param("user") User user);

    void setPwdByMail(@Param("user") User user);

    long selectCount();

    void deleteUserById(@Param("user") User user);

}
